Processes keydown events.

<div class="definition">
    keydown(event)
</div>

<div class="arguments">
    <table>
    <tr>
        <td>event</td>
        <td><b>DOM Event</b>, event object corresponding to keydown event</td>
    </tr>
    </table>
</div>

Returns <i>undefined</i>.

<h4>Description</h4>

This method is called internally when a keyboard button is pressed and will process keyboard events (up/down, left/right, enter, space, etc).
This method emits <a class="method" href="w2sidebar.onKeydown">.onKeydown</a> event.
<div style="height: 10px"></div>

This method can be overwritten:
<textarea class="javascript">
let sidebar = new w2sidebar({
    name : 'sidebar',
    img  : 'icon-page',
    nodes: [
        { id: 'id-1', text: 'Level 1' },
        { id: 'id-2', text: 'Level 2' },
        { id: 'id-3', text: 'Level 3' }
    ],
    keydown: function (event) {
        console.log('Custom keydown event.');
    }
});
</textarea>